#pragma once

#ifndef _Bullet_h_
#define _Bullet_h_

#include "Particles/Particle.h"
#include "../Framework/GameComponent.h"

namespace MyGame {

using namespace Framework;

class Bullet :
            public GameComponent {
public:
    Bullet(Game* game);
    virtual ~Bullet(void);
    D3DXVECTOR3 GetDirection() const;
    void SetDirection(D3DXVECTOR3 val);
    D3DXVECTOR3 GetPosition() const;
    void SetPosition(D3DXVECTOR3 val);
    D3DXVECTOR3 GetPrevPosition() const;
    bool IsAlive() const;
    virtual void Update(FLOAT timeDelta);
private:
    D3DXVECTOR3 direction;
    Particle* particle;
    D3DXVECTOR3 position;
    D3DXVECTOR3 prevPosition;
    FLOAT speed;
    FLOAT timer;
};

}

#endif
